package gov.fema.hazus.bdc.server.guice;


import gov.fema.hazus.bdc.client.login.LoginService;
import gov.fema.hazus.bdc.client.services.BuildingService;
import gov.fema.hazus.bdc.client.services.UserService;
import gov.fema.hazus.bdc.server.servlet.BuildingServlet;
import gov.fema.hazus.bdc.server.servlet.GuiceRemoteServiceServlet;
import gov.fema.hazus.bdc.server.servlet.LoginServlet;
import gov.fema.hazus.bdc.server.servlet.UserServlet;
import com.google.inject.servlet.ServletModule;

public class AppServletModule extends ServletModule {

	@Override
	public void configureServlets() {
		
		// All RPCs handled by Guice wrapper around RemoteServiceServlet
		serve("/buildingdatacollector/gwt.rpc").with(GuiceRemoteServiceServlet.class);
		bind(BuildingService.class).to(BuildingServlet.class);
		bind(UserService.class).to(UserServlet.class);
		bind(LoginService.class).to(LoginServlet.class);
	}

}